<section id="setuser">
    <section class="userTop">
        <header nz-row>
            <div nz-col [nzSpan]="6">
                <label>
                    <span>姓名</span>
                </label>
                <nz-input [(ngModel)]="parts.userName" [nzPlaceHolder]="'用户姓名'" [nzSize]="'large'"></nz-input>
            </div>
            <div nz-col [nzSpan]="6">
                <label>
                    <span>联系方式</span>
                </label>
                <nz-input [(ngModel)]="parts.mobile" [nzPlaceHolder]="'联系电话'" [nzSize]="'large'"></nz-input>
            </div>
            <div nz-col [nzSpan]="6">
                <label>
                    <span>岗位</span>
                </label>
                <!-- <nz-input [(ngModel)]="parts.positionName" [nzPlaceHolder]="'岗位查询'" [nzSize]="'large'"></nz-input> -->
                <nz-select [(ngModel)]="parts.positionName" [nzSize]="'large'" [nzPlaceHolder]="'请选择岗位'" nzAllowClear>
                    <nz-option *ngFor="let option of optionPostion" [nzLabel]="option.text" [nzValue]="option.text">
                    </nz-option>
                </nz-select>
            </div>
        </header>
        <main class="clearfix">
            <button class="fr" nz-button [nzType]="'primary'" (click)="loadAll()">
              <i class="anticon anticon-search"></i><span>检索</span>
            </button>
        </main>
        <footer>
            <button nz-button [nzType]="'default'" routerLink="../userdia">
              <span>添加</span>
            </button>
        </footer>
    </section>
    <section>
        <main>
            <nz-table #nzTable [nzAjaxData]="data" [nzTotal]="_total" [nzPageSize]="10" (nzPageIndexChange)="resetIndex($event)">
                <thead nz-thead>
                    <tr>
                        <th nz-th><span>序号</span></th>
                        <th nz-th><span>姓名</span></th>
                        <th nz-th><span>联系方式</span></th>
                        <th nz-th><span>岗位</span></th>
                        <th nz-th><span>注册时间</span></th>
                        <th nz-th><span>操作</span></th>
                    </tr>
                </thead>
                <tbody nz-tbody>
                    <tr nz-tbody-tr *ngFor="let data of nzTable.data;let i = index">
                        <td nz-td>{{i+1}}</td>
                        <td nz-td>{{data.userName}}</td>
                        <td nz-td>{{data.mobile}}</td>
                        <td nz-td>{{data.positionName}}</td>
                        <td nz-td>{{data.createTime}}</td>
                        <td nz-td>
                            <button nz-button [nzType]="'default'" [routerLink]="['../userinfo', data.userId ]">
                                <span>查看</span>
                            </button>
                            <button nz-button [nzType]="'default'" [routerLink]="['../userdia', data.userId ]">
                                <span>修改</span>
                            </button>
                        </td>
                    </tr>
                </tbody>
            </nz-table>
        </main>
    </section>
</section>